#!/usr/bin/env rake

require 'bundler/setup'

#TODO: This loads ActiveRecord tasks, replace them with Mongoid tasks if any.
load 'rails/tasks/engine.rake'

require 'rake/testtask'
desc 'Test the kopal-rails engine.'
Rake::TestTask.new(:test) do |t|
  t.libs << 'lib'
  t.libs << 'test'
  t.pattern = 'test/{kopal,functional,unit}/*_test.rb'
  t.verbose = true
end

desc 'Tests related with kopal-rails network activity.'
Rake::TestTask.new(:"test-network") do |t|
  t.libs << 'lib'
  t.libs << 'test'
  t.pattern = 'test/network/*_test.rb'
  t.verbose = true
end

task :default => :test